home *** CD-ROM | disk | FTP | other *** search
/ Celestin Apprentice 5 / Apprentice-Release5.iso / Source Code / C / Snippets / Help Dialog / help.µ.rsrc / help.µ.rsrc.adf / TEXT_129.txt < prev    next >
Text File  |  1996-06-04  |  3KB  |  64 lines

  1. Creating 'TEXT'/'styl' Resources
  2.  
  3. Using SimpleText
  4.  
  5. It is probably best to write the text for each of your 'TEXT'/'styl' resources using SimpleText.  Don't worry about the insertion of your non-breaking space characters until you have produced the final draft in the fonts and font sizes of your choice, and with all bolding, italicizing, underlining, etc., complete.  Then decide where your pictures should go and insert a single non-breaking space character (press Option-Spacebar) at each of those points.  
  6.  
  7. Remember that the top of the picture will be aligned with the top of the non-breaking space character, so the normal procedure will be to hit Return twice at the end of the paragraph, hit Option-Spacebar, and then hit Return enough times to create a gap in your text large enough to accommodate the height of the picture.  (You may have to fine tune the size of the gap later, but that can be done quite easily within ResEdit, which has its own text editor for creating and modifying 'TEXT'/'styl' resources.)
  8.  
  9. Creating the 'TEXT' and 'styl' Resource
  10.  
  11. Within SimpleText, copy all the text to the clipboard.  Then open your resource file using ResEdit.   Choose Paste from ResEdit's Edit menu.  The 'TEXT' and 'styl' resources will be created and the associated icons will appear in the ResEdit window.
  12.  
  13. Modifying the 'TEXT' Resource Within ResEdit
  14.  
  15. Double-click on the 'TEXT' icon.  When the 'TEXT'/'styl' resources window opens, click on the line showing the ID of the resource you have just created.  A text editing window opens showing the styled text as you created it.  It is probably best to fine tune the picture gaps, or make any last-minute changes to the text, using this text editor.
  16.  
  17.  
  18.  
  19.  
  20.  
  21.  
  22.  
  23.  
  24.  
  25.  
  26.  
  27.  
  28.  
  29.  
  30. Of course, you can use ResEdit's text editor to do the whole writing task from scratch if you like.  It is more than adequate for that purpose. 
  31.  
  32. Finding the Non-Breaking Space Character
  33.  
  34. If you perform some heavy editing in the vicinity if the non-breaking space character, you may lose track of its location, inadvertently delete it, or move it to an unsuitable position.  To find the character (assuming you have not inadvertently deleted it), click on the relevant resource ID in the 'TEXT''styl' resources window and choose Open Using Hex Editor from the Resource menu.  The hexadecimal editor opens.  You can locate the character in this window.  If you want to delete it and insert it in a new location, simply use the ASCII representation column (on the right) as if it were a normal text editor.
  35.  
  36.  
  37.  
  38.  
  39.  
  40.  
  41.  
  42.  
  43.  
  44.  
  45.  
  46.  
  47.  
  48. Coloured Text
  49.  
  50. Unfortunately, neither SimpleText nor ResEdit's text editor allow you to apply colour to your text.  Here is a simple work-around.  Open the 'TEXT' resource for the topic you are reading now.  (Its ID is 129.)  In ResEdit's text editor, locate the following coloured text and copy the text in the desired colour to the clipboard.  Open your own 'TEXT' resource in ResEdit's text editor and paste the coloured text to the desired location.  Type the required text into the middle of the word you have just pasted, and then delete the extraneous characters.  Finally, apply the font, font size, bolding, etc, of your choice.
  51.  
  52.       Red
  53.     Green
  54.     Blue
  55.     Cyan
  56.     Magenta
  57.     Yellow
  58.     Black
  59.     (White)
  60.  
  61. Modifying the Popup Menu Resource
  62.  
  63. When you have created the 'TEXT" resources for all your help topics, do not forget to modify the popup menu's 'MENU' resource to reflect the number of your help topics and their titles.
  64.